3.1.61 \(\int \frac {(a+a \sec (e+f x))^{5/2}}{(c-c \sec (e+f x))^2} \, dx\) [61]

Optimal. Leaf size=74 \[ \frac {2 a^{5/2} \text {ArcTan}\left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{c^2 f}-\frac {8 a \cot ^3(e+f x) (a+a \sec (e+f x))^{3/2}}{3 c^2 f} \]

[Out]

2*a^(5/2)*arctan(a^(1/2)*tan(f*x+e)/(a+a*sec(f*x+e))^(1/2))/c^2/f-8/3*a*cot(f*x+e)^3*(a+a*sec(f*x+e))^(3/2)/c^
2/f

________________________________________________________________________________________

Rubi [A]
time = 0.11, antiderivative size = 74, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 4, integrand size = 28, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.143, Rules used = {3989, 3972, 472, 209} \begin {gather*} \frac {2 a^{5/2} \text {ArcTan}\left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {a \sec (e+f x)+a}}\right )}{c^2 f}-\frac {8 a \cot ^3(e+f x) (a \sec (e+f x)+a)^{3/2}}{3 c^2 f} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(a + a*Sec[e + f*x])^(5/2)/(c - c*Sec[e + f*x])^2,x]

[Out]

(2*a^(5/2)*ArcTan[(Sqrt[a]*Tan[e + f*x])/Sqrt[a + a*Sec[e + f*x]]])/(c^2*f) - (8*a*Cot[e + f*x]^3*(a + a*Sec[e
 + f*x])^(3/2))/(3*c^2*f)

Rule 209

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1/(Rt[a, 2]*Rt[b, 2]))*ArcTan[Rt[b, 2]*(x/Rt[a, 2])], x] /;
 FreeQ[{a, b}, x] && PosQ[a/b] && (GtQ[a, 0] || GtQ[b, 0])

Rule 472

Int[(((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_))/((c_) + (d_.)*(x_)^(n_)), x_Symbol] :> Int[ExpandIntegr
and[(e*x)^m*((a + b*x^n)^p/(c + d*x^n)), x], x] /; FreeQ[{a, b, c, d, e, m}, x] && NeQ[b*c - a*d, 0] && IGtQ[n
, 0] && IGtQ[p, 0] && (IntegerQ[m] || IGtQ[2*(m + 1), 0] ||  !RationalQ[m])

Rule 3972

Int[cot[(c_.) + (d_.)*(x_)]^(m_.)*(csc[(c_.) + (d_.)*(x_)]*(b_.) + (a_))^(n_.), x_Symbol] :> Dist[-2*(a^(m/2 +
 n + 1/2)/d), Subst[Int[x^m*((2 + a*x^2)^(m/2 + n - 1/2)/(1 + a*x^2)), x], x, Cot[c + d*x]/Sqrt[a + b*Csc[c +
d*x]]], x] /; FreeQ[{a, b, c, d}, x] && EqQ[a^2 - b^2, 0] && IntegerQ[m/2] && IntegerQ[n - 1/2]

Rule 3989

Int[(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_.)*(csc[(e_.) + (f_.)*(x_)]*(d_.) + (c_))^(n_.), x_Symbol] :> Di
st[((-a)*c)^m, Int[Cot[e + f*x]^(2*m)*(c + d*Csc[e + f*x])^(n - m), x], x] /; FreeQ[{a, b, c, d, e, f, n}, x]
&& EqQ[b*c + a*d, 0] && EqQ[a^2 - b^2, 0] && IntegerQ[m] && RationalQ[n] &&  !(IntegerQ[n] && GtQ[m - n, 0])

Rubi steps

\begin {align*} \int \frac {(a+a \sec (e+f x))^{5/2}}{(c-c \sec (e+f x))^2} \, dx &=\frac {\int \cot ^4(e+f x) (a+a \sec (e+f x))^{9/2} \, dx}{a^2 c^2}\\ &=-\frac {(2 a) \text {Subst}\left (\int \frac {\left (2+a x^2\right )^2}{x^4 \left (1+a x^2\right )} \, dx,x,-\frac {\tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{c^2 f}\\ &=-\frac {(2 a) \text {Subst}\left (\int \left (\frac {4}{x^4}+\frac {a^2}{1+a x^2}\right ) \, dx,x,-\frac {\tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{c^2 f}\\ &=-\frac {8 a \cot ^3(e+f x) (a+a \sec (e+f x))^{3/2}}{3 c^2 f}-\frac {\left (2 a^3\right ) \text {Subst}\left (\int \frac {1}{1+a x^2} \, dx,x,-\frac {\tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{c^2 f}\\ &=\frac {2 a^{5/2} \tan ^{-1}\left (\frac {\sqrt {a} \tan (e+f x)}{\sqrt {a+a \sec (e+f x)}}\right )}{c^2 f}-\frac {8 a \cot ^3(e+f x) (a+a \sec (e+f x))^{3/2}}{3 c^2 f}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 4.36, size = 102, normalized size = 1.38 \begin {gather*} -\frac {\cos ^{\frac {5}{2}}(e+f x) \left (-3 \text {ArcSin}\left (\sqrt {1-\cos (e+f x)}\right ) (1-\cos (e+f x))^{3/2}+4 \cos ^{\frac {3}{2}}(e+f x)\right ) \csc ^3\left (\frac {1}{2} (e+f x)\right ) \sec ^5\left (\frac {1}{2} (e+f x)\right ) (a (1+\sec (e+f x)))^{5/2}}{24 c^2 f} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(a + a*Sec[e + f*x])^(5/2)/(c - c*Sec[e + f*x])^2,x]

[Out]

-1/24*(Cos[e + f*x]^(5/2)*(-3*ArcSin[Sqrt[1 - Cos[e + f*x]]]*(1 - Cos[e + f*x])^(3/2) + 4*Cos[e + f*x]^(3/2))*
Csc[(e + f*x)/2]^3*Sec[(e + f*x)/2]^5*(a*(1 + Sec[e + f*x]))^(5/2))/(c^2*f)

________________________________________________________________________________________

Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(350\) vs. \(2(64)=128\).
time = 0.20, size = 351, normalized size = 4.74

method result size
default \(-\frac {\left (3 \left (\cos ^{3}\left (f x +e \right )\right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \arctanh \left (\frac {\sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) \sqrt {2}}{2 \cos \left (f x +e \right )}\right ) \sqrt {2}-3 \left (\cos ^{2}\left (f x +e \right )\right ) \sqrt {2}\, \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \arctanh \left (\frac {\sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) \sqrt {2}}{2 \cos \left (f x +e \right )}\right )-3 \cos \left (f x +e \right ) \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \arctanh \left (\frac {\sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) \sqrt {2}}{2 \cos \left (f x +e \right )}\right ) \sqrt {2}+8 \left (\cos ^{2}\left (f x +e \right )\right ) \sin \left (f x +e \right )+3 \sqrt {2}\, \sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \arctanh \left (\frac {\sqrt {-\frac {2 \cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sin \left (f x +e \right ) \sqrt {2}}{2 \cos \left (f x +e \right )}\right )\right ) \sqrt {\frac {a \left (\cos \left (f x +e \right )+1\right )}{\cos \left (f x +e \right )}}\, a^{2}}{3 c^{2} f \left (-1+\cos \left (f x +e \right )\right )^{2} \left (\cos \left (f x +e \right )+1\right )}\) \(351\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+a*sec(f*x+e))^(5/2)/(c-c*sec(f*x+e))^2,x,method=_RETURNVERBOSE)

[Out]

-1/3/c^2/f*(3*cos(f*x+e)^3*(-2*cos(f*x+e)/(cos(f*x+e)+1))^(1/2)*arctanh(1/2*(-2*cos(f*x+e)/(cos(f*x+e)+1))^(1/
2)*sin(f*x+e)/cos(f*x+e)*2^(1/2))*2^(1/2)-3*cos(f*x+e)^2*2^(1/2)*(-2*cos(f*x+e)/(cos(f*x+e)+1))^(1/2)*arctanh(
1/2*(-2*cos(f*x+e)/(cos(f*x+e)+1))^(1/2)*sin(f*x+e)/cos(f*x+e)*2^(1/2))-3*cos(f*x+e)*(-2*cos(f*x+e)/(cos(f*x+e
)+1))^(1/2)*arctanh(1/2*(-2*cos(f*x+e)/(cos(f*x+e)+1))^(1/2)*sin(f*x+e)/cos(f*x+e)*2^(1/2))*2^(1/2)+8*cos(f*x+
e)^2*sin(f*x+e)+3*2^(1/2)*(-2*cos(f*x+e)/(cos(f*x+e)+1))^(1/2)*arctanh(1/2*(-2*cos(f*x+e)/(cos(f*x+e)+1))^(1/2
)*sin(f*x+e)/cos(f*x+e)*2^(1/2)))*(a*(cos(f*x+e)+1)/cos(f*x+e))^(1/2)/(-1+cos(f*x+e))^2/(cos(f*x+e)+1)*a^2

________________________________________________________________________________________

Maxima [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sec(f*x+e))^(5/2)/(c-c*sec(f*x+e))^2,x, algorithm="maxima")

[Out]

Timed out

________________________________________________________________________________________

Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 169 vs. \(2 (68) = 136\).
time = 3.54, size = 367, normalized size = 4.96 \begin {gather*} \left [\frac {16 \, a^{2} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \cos \left (f x + e\right )^{2} + 3 \, {\left (a^{2} \cos \left (f x + e\right ) - a^{2}\right )} \sqrt {-a} \log \left (-\frac {8 \, a \cos \left (f x + e\right )^{3} - 4 \, {\left (2 \, \cos \left (f x + e\right )^{2} - \cos \left (f x + e\right )\right )} \sqrt {-a} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \sin \left (f x + e\right ) - 7 \, a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right ) + 1}\right ) \sin \left (f x + e\right )}{6 \, {\left (c^{2} f \cos \left (f x + e\right ) - c^{2} f\right )} \sin \left (f x + e\right )}, \frac {8 \, a^{2} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \cos \left (f x + e\right )^{2} + 3 \, {\left (a^{2} \cos \left (f x + e\right ) - a^{2}\right )} \sqrt {a} \arctan \left (\frac {2 \, \sqrt {a} \sqrt {\frac {a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \cos \left (f x + e\right ) \sin \left (f x + e\right )}{2 \, a \cos \left (f x + e\right )^{2} + a \cos \left (f x + e\right ) - a}\right ) \sin \left (f x + e\right )}{3 \, {\left (c^{2} f \cos \left (f x + e\right ) - c^{2} f\right )} \sin \left (f x + e\right )}\right ] \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sec(f*x+e))^(5/2)/(c-c*sec(f*x+e))^2,x, algorithm="fricas")

[Out]

[1/6*(16*a^2*sqrt((a*cos(f*x + e) + a)/cos(f*x + e))*cos(f*x + e)^2 + 3*(a^2*cos(f*x + e) - a^2)*sqrt(-a)*log(
-(8*a*cos(f*x + e)^3 - 4*(2*cos(f*x + e)^2 - cos(f*x + e))*sqrt(-a)*sqrt((a*cos(f*x + e) + a)/cos(f*x + e))*si
n(f*x + e) - 7*a*cos(f*x + e) + a)/(cos(f*x + e) + 1))*sin(f*x + e))/((c^2*f*cos(f*x + e) - c^2*f)*sin(f*x + e
)), 1/3*(8*a^2*sqrt((a*cos(f*x + e) + a)/cos(f*x + e))*cos(f*x + e)^2 + 3*(a^2*cos(f*x + e) - a^2)*sqrt(a)*arc
tan(2*sqrt(a)*sqrt((a*cos(f*x + e) + a)/cos(f*x + e))*cos(f*x + e)*sin(f*x + e)/(2*a*cos(f*x + e)^2 + a*cos(f*
x + e) - a))*sin(f*x + e))/((c^2*f*cos(f*x + e) - c^2*f)*sin(f*x + e))]

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \frac {\int \frac {a^{2} \sqrt {a \sec {\left (e + f x \right )} + a}}{\sec ^{2}{\left (e + f x \right )} - 2 \sec {\left (e + f x \right )} + 1}\, dx + \int \frac {2 a^{2} \sqrt {a \sec {\left (e + f x \right )} + a} \sec {\left (e + f x \right )}}{\sec ^{2}{\left (e + f x \right )} - 2 \sec {\left (e + f x \right )} + 1}\, dx + \int \frac {a^{2} \sqrt {a \sec {\left (e + f x \right )} + a} \sec ^{2}{\left (e + f x \right )}}{\sec ^{2}{\left (e + f x \right )} - 2 \sec {\left (e + f x \right )} + 1}\, dx}{c^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sec(f*x+e))**(5/2)/(c-c*sec(f*x+e))**2,x)

[Out]

(Integral(a**2*sqrt(a*sec(e + f*x) + a)/(sec(e + f*x)**2 - 2*sec(e + f*x) + 1), x) + Integral(2*a**2*sqrt(a*se
c(e + f*x) + a)*sec(e + f*x)/(sec(e + f*x)**2 - 2*sec(e + f*x) + 1), x) + Integral(a**2*sqrt(a*sec(e + f*x) +
a)*sec(e + f*x)**2/(sec(e + f*x)**2 - 2*sec(e + f*x) + 1), x))/c**2

________________________________________________________________________________________

Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 243 vs. \(2 (64) = 128\).
time = 1.45, size = 243, normalized size = 3.28 \begin {gather*} -\frac {\sqrt {2} \sqrt {-a} a^{5} {\left (\frac {3 \, \sqrt {2} \log \left (\frac {{\left | 2 \, {\left (\sqrt {-a} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - \sqrt {-a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + a}\right )}^{2} - 4 \, \sqrt {2} {\left | a \right |} - 6 \, a \right |}}{{\left | 2 \, {\left (\sqrt {-a} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - \sqrt {-a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + a}\right )}^{2} + 4 \, \sqrt {2} {\left | a \right |} - 6 \, a \right |}}\right )}{a^{2} c^{2} {\left | a \right |}} + \frac {8 \, {\left (3 \, {\left (\sqrt {-a} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - \sqrt {-a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + a}\right )}^{4} + a^{2}\right )}}{{\left ({\left (\sqrt {-a} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - \sqrt {-a \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} + a}\right )}^{2} - a\right )}^{3} a^{2} c^{2}}\right )} \mathrm {sgn}\left (\cos \left (f x + e\right )\right )}{6 \, f} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sec(f*x+e))^(5/2)/(c-c*sec(f*x+e))^2,x, algorithm="giac")

[Out]

-1/6*sqrt(2)*sqrt(-a)*a^5*(3*sqrt(2)*log(abs(2*(sqrt(-a)*tan(1/2*f*x + 1/2*e) - sqrt(-a*tan(1/2*f*x + 1/2*e)^2
 + a))^2 - 4*sqrt(2)*abs(a) - 6*a)/abs(2*(sqrt(-a)*tan(1/2*f*x + 1/2*e) - sqrt(-a*tan(1/2*f*x + 1/2*e)^2 + a))
^2 + 4*sqrt(2)*abs(a) - 6*a))/(a^2*c^2*abs(a)) + 8*(3*(sqrt(-a)*tan(1/2*f*x + 1/2*e) - sqrt(-a*tan(1/2*f*x + 1
/2*e)^2 + a))^4 + a^2)/(((sqrt(-a)*tan(1/2*f*x + 1/2*e) - sqrt(-a*tan(1/2*f*x + 1/2*e)^2 + a))^2 - a)^3*a^2*c^
2))*sgn(cos(f*x + e))/f

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {{\left (a+\frac {a}{\cos \left (e+f\,x\right )}\right )}^{5/2}}{{\left (c-\frac {c}{\cos \left (e+f\,x\right )}\right )}^2} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a + a/cos(e + f*x))^(5/2)/(c - c/cos(e + f*x))^2,x)

[Out]

int((a + a/cos(e + f*x))^(5/2)/(c - c/cos(e + f*x))^2, x)

________________________________________________________________________________________